<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <title>Vue.js控制元素属性</title>
    <script src="vue.js"></script>
</head>
<body>
    <div id="demo">
        <a  href="#" v-bind:href="hrefvalue">
            <img v-bind:class="c" src="logo.png" alt="">
        </a>
    </div>
    <script>
        var app=new Vue({
            el:'#demo',
            data:{
                hrefvalue:'http://www.baidu.com',
                c:'myred'
            }
        });
    </script>
</body>
</html>
